package com.erp.erp_entitys.BillExchangeInfo;

import com.erp.annotation.PropertyMsg;
import com.erp.erp_entitys.business.entity.CarryDetailEntity;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

/**
 * 结汇主信息表(BillExchangeInfo)实体类
 *
 * @author cj
 * @since 2021-01-15 21:07:04
 */
public class BillExchangeInfo implements Serializable {
    private static final long serialVersionUID = -54839201865700423L;
    /**
     * 结汇ID
     */
    private Integer billId;
    /**
     * 客户编码
     */
    private String custCode;
    /**
     * 客户名称
     */
    private String customerName;
    /**
     * 发票号码
     */
    private String invoiceNo;
    /**
     * 发票日期
     */
    @DateTimeFormat(pattern="yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private Date invoiceDate;
    /**
     * 单据类型
     */
    private String billType;
    /**
     * 外销合同号
     */
    @PropertyMsg("外销合同号")
    private String contractNo;
    /**
     * 客户合同号
     */
    @PropertyMsg("客户合同号")
    private String custContractNo;
    /**
     * 发票金额
     */
    @PropertyMsg("发票金额")
    private BigDecimal invoiceMoney;
    /**
     * 联系人
     */
    @PropertyMsg("联系人")
    private String linker;
    /**
     * 签约公司ID
     */
    private String companyCode;
    /**
     * 签约公司名称
     */
    @PropertyMsg("签约公司名称")
    private String companyName;
    /**
     * 币种
     */
    @PropertyMsg("币种")
    private String moneyKind;
    /**
     * 人民币汇率
     */
    private BigDecimal rmbRate;
    /**
     * 美元汇率
     */
    private BigDecimal usdRate;
    /**
     * 起运地
     */
    @PropertyMsg("起运地")
    private String startPlace;
    /**
     * 目的地
     */
    @PropertyMsg("目的地")
    private String endPlace;
    /**
     * 运输方式
     */
    @PropertyMsg("运输方式")
    private String transMode;
    /**
     * 价格术语
     */
    @PropertyMsg("价格术语")
    private String priceTerm;
    /**
     * 收款（结汇）方式
     */
    @PropertyMsg("收款（结汇）方式")
    private String settleMode;
    /**
     * 预计结汇日期
     */
    @PropertyMsg("预计结汇日期")
    @DateTimeFormat(pattern="yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private Date settleDate;
    /**
     * 出运日期
     */
    @PropertyMsg("出运日期")
    @DateTimeFormat(pattern="yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private Date shippingDate;
    /**
     * 银行编码
     */
    private String bankCode;
    /**
     * 银行名称
     */
    @PropertyMsg("银行名称")
    private String bankName;
    /**
     * 制单日期
     */
    @DateTimeFormat(pattern="yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private Date createTime;
    /**
     * 编辑时间
     */
    @DateTimeFormat(pattern="yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private Date editTime;
    /**
     * 操作员编号
     */
    private String opcode;
    /**
     * 操作员姓名
     */
    private String opname;
    /**
     * 业务员
     */
    private String salesman;
    /**
     * 业务员编码
     */
    private String salesmanCode;
    /**
     * 状态(1.草稿箱 2.待批箱 3.已批箱 4.完成箱 5.垃圾箱)
     */
    private Integer status;
    /**
     * 业务模式
     */
    @PropertyMsg("业务模式")
    private String businessMode;
    /**
     * 仓库
     */
    @PropertyMsg("仓库")
    private String stock;
    /**
     * 账期
     */
    @PropertyMsg("账期")
    private String payday;
    /**
     * 逾期
     */
    @PropertyMsg("逾期")
    private String overdue;
    /**
     * 出运发票号
     */
    private String carryInvoiceNo;
    /**
     * 备注
     */
    @PropertyMsg("备注")
    private String asPerInNo;
    /**
     * 总关税金额
     */
    @PropertyMsg("总关税金额")
    private BigDecimal totalTariffAmount;
    /**
     * 实际开船日期
     */
    @PropertyMsg("实际开船日期")
    @DateTimeFormat(pattern="yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private Date actualAtd;
    /**
     * 进仓装柜日期
     */
    @PropertyMsg("进仓装柜日期")
    @DateTimeFormat(pattern="yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private Date instockDate;
    /**
     * 客户等级
     */
    private String customerLevelName;
    /**
     * 客户等级编码
     */
    private String customerLevelCode;
    /**
     * 是否走信保订单(0:否 1:是)
     */
    private Integer whetherCreditGuarantee;

    /**
     * 信保订单金额USD
     */
    private BigDecimal creditGuaranteeAmount;
    public BillExchangeInfo() {
    }

    public BillExchangeInfo(CarryDetailEntity carry){
        this.custCode = carry.getCustomerCode();
        this.customerName = carry.getCustomerCode();
        this.invoiceNo = carry.getBillNo();
        this.invoiceDate = carry.getCreateDate();
        this.contractNo = carry.getSalesContractNo();
        this.custContractNo =carry.getCustomerContractNo();
        this.invoiceMoney = carry.getTotalInvoiceAmount();
        this.companyCode = carry.getSigningCompanyCode();
        this.companyName = carry.getSigningCompanyName();
        this.moneyKind =carry.getCurrency();
        this.rmbRate = carry.getRmbRate();
        this.usdRate = carry.getUsdRate();
        this.startPlace = carry.getTransitPlaceName();
        this.endPlace = carry.getDestinationName();
        this.transMode = carry.getModeOfTransport();
        this.priceTerm = carry.getPriceTermsName();
        this.settleMode = carry.getPaymentMethodName();
        this.shippingDate = carry.getTime();
        this.bankCode = carry.getBankCode();
        this.bankName = carry.getBankName();
        this.opcode = carry.getOperationCode();
        this.opname = carry.getOperator();
        this.salesman = carry.getSalesmanName();
        this.salesmanCode = carry.getSalesmanCode();
        this.businessMode = carry.getBusinessModelName();
        this.stock = carry.getWarehouseName();
        this.payday =carry.getAccountingPeriod();
        this.carryInvoiceNo = carry.getBillNo();
        this.actualAtd = carry.getActualTimeDismissal();
        this.instockDate = carry.getLoadingTime();
        this.customerLevelName=carry.getCustomerLevelName();
        this.customerLevelCode=carry.getCustomerLevelCode();
        this.whetherCreditGuarantee=carry.getWhetherCreditGuarantee();
        this.creditGuaranteeAmount=carry.getCreditGuaranteeAmount();
    }

    public Integer getWhetherCreditGuarantee() {
        return whetherCreditGuarantee;
    }

    public void setWhetherCreditGuarantee(Integer whetherCreditGuarantee) {
        this.whetherCreditGuarantee = whetherCreditGuarantee;
    }

    public BigDecimal getCreditGuaranteeAmount() {
        return creditGuaranteeAmount;
    }

    public void setCreditGuaranteeAmount(BigDecimal creditGuaranteeAmount) {
        this.creditGuaranteeAmount = creditGuaranteeAmount;
    }

    public Integer getBillId() {
        return billId;
    }

    public void setBillId(Integer billId) {
        this.billId = billId;
    }

    public String getCustCode() {
        return custCode;
    }

    public void setCustCode(String custCode) {
        this.custCode = custCode;
    }

    public String getCustomerName() {
        return customerName;
    }

    public void setCustomerName(String customerName) {
        this.customerName = customerName;
    }

    public String getInvoiceNo() {
        return invoiceNo;
    }

    public void setInvoiceNo(String invoiceNo) {
        this.invoiceNo = invoiceNo;
    }

    public Date getInvoiceDate() {
        return invoiceDate;
    }

    public void setInvoiceDate(Date invoiceDate) {
        this.invoiceDate = invoiceDate;
    }

    public String getBillType() {
        return billType;
    }

    public void setBillType(String billType) {
        this.billType = billType;
    }

    public String getContractNo() {
        return contractNo;
    }

    public void setContractNo(String contractNo) {
        this.contractNo = contractNo;
    }

    public String getCustContractNo() {
        return custContractNo;
    }

    public void setCustContractNo(String custContractNo) {
        this.custContractNo = custContractNo;
    }

    public BigDecimal getInvoiceMoney() {
        return invoiceMoney;
    }

    public void setInvoiceMoney(BigDecimal invoiceMoney) {
        this.invoiceMoney = invoiceMoney;
    }

    public String getLinker() {
        return linker;
    }

    public void setLinker(String linker) {
        this.linker = linker;
    }

    public String getCompanyCode() {
        return companyCode;
    }

    public void setCompanyCode(String companyCode) {
        this.companyCode = companyCode;
    }

    public String getCompanyName() {
        return companyName;
    }

    public void setCompanyName(String companyName) {
        this.companyName = companyName;
    }

    public String getMoneyKind() {
        return moneyKind;
    }

    public void setMoneyKind(String moneyKind) {
        this.moneyKind = moneyKind;
    }

    public BigDecimal getRmbRate() {
        return rmbRate;
    }

    public void setRmbRate(BigDecimal rmbRate) {
        this.rmbRate = rmbRate;
    }

    public BigDecimal getUsdRate() {
        return usdRate;
    }

    public void setUsdRate(BigDecimal usdRate) {
        this.usdRate = usdRate;
    }

    public String getStartPlace() {
        return startPlace;
    }

    public void setStartPlace(String startPlace) {
        this.startPlace = startPlace;
    }

    public String getEndPlace() {
        return endPlace;
    }

    public void setEndPlace(String endPlace) {
        this.endPlace = endPlace;
    }

    public String getTransMode() {
        return transMode;
    }

    public void setTransMode(String transMode) {
        this.transMode = transMode;
    }

    public String getPriceTerm() {
        return priceTerm;
    }

    public void setPriceTerm(String priceTerm) {
        this.priceTerm = priceTerm;
    }

    public String getSettleMode() {
        return settleMode;
    }

    public void setSettleMode(String settleMode) {
        this.settleMode = settleMode;
    }

    public Date getSettleDate() {
        return settleDate;
    }

    public void setSettleDate(Date settleDate) {
        this.settleDate = settleDate;
    }

    public Date getShippingDate() {
        return shippingDate;
    }

    public void setShippingDate(Date shippingDate) {
        this.shippingDate = shippingDate;
    }

    public String getBankCode() {
        return bankCode;
    }

    public void setBankCode(String bankCode) {
        this.bankCode = bankCode;
    }

    public String getBankName() {
        return bankName;
    }

    public void setBankName(String bankName) {
        this.bankName = bankName;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public Date getEditTime() {
        return editTime;
    }

    public void setEditTime(Date editTime) {
        this.editTime = editTime;
    }

    public String getOpcode() {
        return opcode;
    }

    public void setOpcode(String opcode) {
        this.opcode = opcode;
    }

    public String getOpname() {
        return opname;
    }

    public void setOpname(String opname) {
        this.opname = opname;
    }

    public String getSalesman() {
        return salesman;
    }

    public void setSalesman(String salesman) {
        this.salesman = salesman;
    }

    public String getSalesmanCode() {
        return salesmanCode;
    }

    public void setSalesmanCode(String salesmanCode) {
        this.salesmanCode = salesmanCode;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public String getBusinessMode() {
        return businessMode;
    }

    public void setBusinessMode(String businessMode) {
        this.businessMode = businessMode;
    }

    public String getStock() {
        return stock;
    }

    public void setStock(String stock) {
        this.stock = stock;
    }

    public String getPayday() {
        return payday;
    }

    public void setPayday(String payday) {
        this.payday = payday;
    }

    public String getOverdue() {
        return overdue;
    }

    public void setOverdue(String overdue) {
        this.overdue = overdue;
    }

    public String getCarryInvoiceNo() {
        return carryInvoiceNo;
    }

    public void setCarryInvoiceNo(String carryInvoiceNo) {
        this.carryInvoiceNo = carryInvoiceNo;
    }

    public String getAsPerInNo() {
        return asPerInNo;
    }

    public void setAsPerInNo(String asPerInNo) {
        this.asPerInNo = asPerInNo;
    }

    public BigDecimal getTotalTariffAmount() {
        return totalTariffAmount;
    }

    public void setTotalTariffAmount(BigDecimal totalTariffAmount) {
        this.totalTariffAmount = totalTariffAmount;
    }

    public Date getActualAtd() {
        return actualAtd;
    }

    public void setActualAtd(Date actualAtd) {
        this.actualAtd = actualAtd;
    }

    public Date getInstockDate() {
        return instockDate;
    }

    public void setInstockDate(Date instockDate) {
        this.instockDate = instockDate;
    }

    public String getCustomerLevelName() {
        return customerLevelName;
    }

    public void setCustomerLevelName(String customerLevelName) {
        this.customerLevelName = customerLevelName;
    }

    public String getCustomerLevelCode() {
        return customerLevelCode;
    }

    public void setCustomerLevelCode(String customerLevelCode) {
        this.customerLevelCode = customerLevelCode;
    }
}